<?php

class Admin_Settings_model extends CI_Model{


	//retrieve all settings data
	function listSettings(){
		$this->db->order_by("key", "asc");
		return $this->db->get('mlme_settings');
	}
	function saveConfig($post){
		foreach($post as $key => $value){
			$data = array('value' => $value);
			$this->db->where('key',$key);
			$update = $this->db->update('mlme_settings',$data);
		}//end if
		return ($update)? true:false;
	}

}